import {Component, OnInit} from '@angular/core';
import {EntityService} from '../../shared/services/entity.service';
import {MenuService} from '../service/menu.service';

@Component({
  selector: 'app-menu-index',
  template: `
    <div class="ui-fluid">
      <div class="ui-g">
        <div class="ui-g-12">
          <div class="card no-margin">
            <app-base-search></app-base-search>
          </div>
          <div class="card card-w-title">
            <h1>{{data.title}}11</h1>
            <app-menu-list></app-menu-list>
          </div>
        </div>
      </div>
    </div>
  `,
  providers: [ { provide: EntityService, useClass: MenuService } ]
})
export class MenuIndexComponent implements OnInit {
  constructor(
    private thisService: EntityService
  ) {
  }
  get data(){
    return this.thisService.pageData;
  }
  ngOnInit() {
    console.log(this.thisService.test);
  }
}
